//
//  ChatEnumType.h
//  YunShouHu
//
//  Created by WangQiang on 16/9/18.
//  Copyright © 2016年 WangQiang. All rights reserved.
//

#ifndef ChatEnumType_h
#define ChatEnumType_h


#define TimeH 15.0
#define BottomH 10.0
#define TopH 10.0
#define IconW 40 //头像宽度
#define SendStateFlagW  20 //发送失败的状态标识
#define IconPadding 10 //头像距离边界的距离
#define ContentMinEdgeInset (IconW + IconPadding) //内容距离边距最小的距离
#define contentEdgeW 15.0 //内容的左右边距 (当做头像与内容间的间隔)
#define contentEdgeH 10.0 //内容的上下边距

#define ImageInsetH 5.0 //图片的时候上下补偿
#define TextInsetH 4.0
//#define AudioInsetH 
#define MaxTextWidth (APP_WIGHT - IconW *2 - contentEdgeW*2 - SendStateFlagW - IconPadding*2) //文字的最大宽度
//内容的最大宽度
#define MaxContentWidth (APP_WIGHT - ContentMinEdgeInset -IconPadding -SendStateFlagW - contentEdgeW *2 - IconW*2)

#define TextFont MYFont(16.0)
#define TimeFont MYFont(13.0)

static CGFloat const maxAudioLegth = 60.0;
static CGFloat const minChatTimeInterval = 60*10.0;//10分钟内的不显示时间

typedef NS_ENUM(int32_t,ChatMessageType){
    ChatMessageTypeDefault = 0,
    ChatMessageTypeText,//文字
    ChatMessageTypeVoice,//语音
    ChatMessageTypePhoto,
    ChatMessageTypeDocument,//文件
};
typedef NS_ENUM(int32_t , ShowMessageType) {
    ShowMessageTypeMe = 10,
    ShowMessageTypeOther,
};

//typedef NS_ENUM(int32_t ,RS_State){
//    RSS_Default,
//    SState_Success,
//    SState_Sending,
//    SState_Failed,
//    RState_Loading,
//    RState_Reading,
//    RState_Readed,
//    RState_Failed,
//    RState_None,
//};
typedef NS_ENUM(int32_t , MessageSendState) {
    MessageSendStateDefault,
    MessageSendStateSuccess,
    MessageSendStateSending,//正在发送中
    MessageSendStateFailed,
};
typedef NS_ENUM(int32_t ,ReadState){
    ReadStateDefault,
    ReadStateLoadSource,//正在加载资源
    ReadStateReading,//正在播放
    ReadStateReaded,//播放结束
    ReadStateReadFailed,//播放失败
    ReadStateNone,//没有阅读过
};

#endif /* ChatEnumType_h */
